#pragma once


#include "models/file_info.hpp"
#include <optional>
#include <vector>

class FileDao {
public:
    static bool saveFile(const FileInfo& file);
    static std::vector<FileInfo> getFilesByUser(int uid, int limit = 10);
    static std::optional<FileInfo> getFileByHashAndUser(const std::string& hashcode, int uid);
    static bool deleteFileByUser(int fileId, int userId);
    // static bool deleteFile(int fileId);
    static bool updateFileStatus(const std::string& hashcode, int status);

};


